﻿using Harmontronics.Model.Dto.Login;
using Harmontronics.Model.Dto.User;
using Harmontronics.Model.Entitys;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Harmontronics.IService
{
    public interface IUserService
    {
        /// <summary>
        /// 登录用
        /// </summary>
        /// <param name="userName"></param>
        /// <param name="password"></param>
        /// <returns></returns>
        UserRes GetUser(string userName, string password);

        /// <summary>
        /// 添加
        /// </summary>
        /// <param name="role"></param>
        /// <param name="userId"></param>
        /// <returns></returns>
        bool AddUser(UserAdd input);
        /// <summary>
        /// 修改
        /// </summary>
        /// <param name="role"></param>
        /// <param name="userId"></param>
        /// <returns></returns>
        bool Update(UserEdit role);
        //重置密码或者状态
        bool ResetPwdOrStatus(ResetPwdInput input);
        /// <summary>
        /// 删除
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        bool DeleteUser(int id);

        /// <summary>
        /// 批量删除
        /// </summary>
        /// <param name="ids"></param>
        /// <returns></returns>
        bool BatchDel(List<int> ids);

        /// <summary>
        /// 获取用户列表
        /// </summary>
        /// <param name="req"></param>
        /// <returns></returns>
        List<UserReq> GetUsersList();

        /// <summary>
        /// 根据id获取单个用户
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        UserReq GetUserReqById(int id);
        Users GetUsersById(int id);
        /// <summary>
        /// 根据emp获取单个用户
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        UserReq GetUsersByEmp(string emp);
        /// <summary>
        /// 删除头像
        /// </summary>
        /// <param name="UserId"></param>
        /// <returns></returns>
        bool DeleteHeadPortrait(string employeeNumber);
        /// <summary>
        /// 存头像
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        ApiResponseData SaveHeadPortrait(FileupLoadInput input);

    }
}
